package com.hmdp.utils;

/**
 * 设置redis操作有关的一些常量
 */
public class RedisConstants {
    //存储验证码的key的业务前缀
    public static final String LOGIN_CODE_KEY = "login:code:";
    //存储验证码的有效时间
    public static final Long LOGIN_CODE_TTL = 2L;

    //解决缓存穿透--缓存控制的有效时间
    public static final Long CACHE_NULL_TTL = 2L;

    //redis中店铺信息的过期时间
    public static final Long CACHE_SHOP_TTL = 30L;

    //短信登陆功能的业务前缀
    public static final String LOGIN_USER_KEY = "login:token:";
    //仿照session的redis中用户信息的有效时间
    public static final Long LOGIN_USER_TTL = 30L;

    //店铺缓存的业务前缀
    public static final String CACHE_SHOP_KEY = "cache:shop:";

    //店铺缓存的业务前缀
    public static final String CACHE_TYPE_KEY = "cache:type";

    public static final String LOCK_SHOP_KEY = "lock:shop";
    public static final Long Lock_SHOP_TTL = 10L;

    public static final String SECKILL_STOCK_KEY = "seckill:stock:";

    public static final String BLOG_LIKED_KEY = "blog:liked:";

    public static final String FEED_KEY = "feed:";
    public static final String SHOP_GEO_KEY = "shop:geo";

    public static final String USER_SIGN_KEY = "sign:";


}
